/*
 * Copyright 2014, Gregg Tavares.
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are
 * met:
 *
 *     * Redistributions of source code must retain the above copyright
 * notice, this list of conditions and the following disclaimer.
 *     * Redistributions in binary form must reproduce the above
 * copyright notice, this list of conditions and the following disclaimer
 * in the documentation and/or other materials provided with the
 * distribution.
 *     * Neither the name of Gregg Tavares. nor the names of its
 * contributors may be used to endorse or promote products derived from
 * this software without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 */
html, body {
    background-color: purple;
}
#buttons {
    position: absolute;
    -moz-user-select: none;
    -webkit-user-select: none;
    -o-user-select: none;
    user-select: none;
}
#bombs {
    width: 100%;
    height: 16px;
}
#bombsize {
    width: 100%;
    height: 16px;
}
.button {
    background-color: #AAA;
    color: #666;
    border: 2px solid #444;
    border-radius: 80px;
    width: 160px;
    height: 160px;
    text-align: center;
    font-size: 120px;
    font-family: Helvetica, Arial, sans-serif;
    font-weight: bold;
    position: absolute;
    line-height: 133%;
}

#dpadleft, #abutton {
  position: absolute;
  width: 160px;
  bottom: 40px;
}
#dpadleft {
  left: 20px;
}
#dpadleftinput {
  position: absolute;
  left: 0px;
  bottom: 0px;
  width: 45%;
  height: 100%;
  gbackground-color: rgba(0,255,0,0.3);
}
#abutton {
  right: 20px;
  bottom: 46px;  /* why is this 46 not 40? */
}
#abuttoninput {
  position: absolute;
  right: 0px;
  bottom: 0px;
  height: 100%;
  width: 45%;
  gbackground-color: rgba(0,255,255,0.3);
}
#avatar {
  position: absolute;
  left: 50%;
  margin-left: -64px;
  bottom: 100px;
  width: 128px;
  height: 128px;
}
#avatarinput {
  position: absolute;
  left: 45%;
  bottom: 0px;
  width: 10%;
  height: 100%;
  gbackground-color: rgba(255,255,255,0.7);
}
#msgcontainer {
  position: absolute;
  left: 0px;
  top: 0px;
  width: 100%;
  height: 100%;
  z-index: 2;
  background-color: #48F;

  display: -webkit-box;
  display: -webkit-flex;
  display: flex;

  -webkit-box-orient: vertical;
  -webkit-flex-flow: column;
  flex-flow: column;

  -webkit-box-pack: center;
  -webkit-justify-content: center;
  -webkit-align-content: center;
  -webkit-align-items: center;

  justify-content: center;
  align-content: center;
  align-items: center;

  min-height: auto;
}

#msg {
  color: white;
  text-align: center;

  -webkit-box-flex: 0;
  -webkit-flex: 0 0 auto;
  flex: 0 0 auto;

  font-size: xx-large;
  font-weight: bold;
}

/* iOS 6 the chrome takes more space */
@media only screen and (max-height : 319px) {
    .button {
        width: 144px;
        height: 144px;
        border-radius: 70px;
    }
    #dpadleft {
        bottom: 0px;
    }
    #abutton {
        bottom: 10px;
    }
    #avatar {
      bottom: 10px;
    }
}
